-- Winter Anathema (c) v.v.balashoff
local Domain = require('leviathan/ECS/Domain')
--local Entity = require('leviathan/ECS/Entity')
local EventSystem = require('leviathan/ECS/Input/Systems/EventSystem')
local MouseRemoveTempSystem = require('leviathan/ECS/Input/Systems/MouseRemoveTempSystem')

local DomainEvents = Domain:derive('Events')

function DomainEvents:new(world)
    -- call parent constructor
    DomainEvents.super.new(self, world, 'Events')
    self.priority = 990
    -- entities
--    local mouse = Entity(self, 'Mouse')
--    local keyboard = Entity(self, 'Keyboard')
    -- components
-- TODO www
--    mouse:addComponent(mouseButtons)
    -- systems
    local event = EventSystem(self)
    local remove = MouseRemoveTempSystem(self)
    -- adding systems
-- TODO www
--    DomainEvents:addSystem(self, click)
    DomainEvents:addSystem(self, event)
    DomainEvents:addSystem(self, remove)
end

return DomainEvents
